package cn.gson.fengboot.model.pojos;

import javax.persistence.*;
import java.math.BigDecimal;
import java.sql.Timestamp;

@Entity
public class Zinvoice {
    private Integer invoiceId;//记录id
    private Zreturnedmoneylog returnedmoneylogId;//回款记录
    private TfyclientForm clientId;//客户
    private String invoiceContent;//开票内容
    private String invoiceType;//票据类型
    private BigDecimal invoiceMoney;//票据金额
    private String invoiceNumber;//发票号码
    private Timestamp invoiceTime;//开票日期
    private String invoiceIssue;//开票记录期次
    private String invoicePerson;//开票记录经手人
    private String invoiceRemark;//开票记录备注
    private Integer invoiceZt;//开票记录状态

    @Id
    @Column(name = "invoice_id")
    @GeneratedValue(strategy = GenerationType.IDENTITY,generator = "zinvoice")
    public Integer getInvoiceId() {
        return invoiceId;
    }

    public void setInvoiceId(Integer invoiceId) {
        this.invoiceId = invoiceId;
    }

    @ManyToOne
    @JoinColumn(name = "returnedmoneylog_id", referencedColumnName = "returnedmoneylog_id")
    public Zreturnedmoneylog getReturnedmoneylogId() {
        return returnedmoneylogId;
    }

    public void setReturnedmoneylogId(Zreturnedmoneylog returnedmoneylogId) {
        this.returnedmoneylogId = returnedmoneylogId;
    }

    @ManyToOne
    @JoinColumn(name = "client_id", referencedColumnName = "client_id")
    public TfyclientForm getClientId() {
        return clientId;
    }

    public void setClientId(TfyclientForm clientId) {
        this.clientId = clientId;
    }

    @Basic
    @Column(name = "invoice_content")
    public String getInvoiceContent() {
        return invoiceContent;
    }

    public void setInvoiceContent(String invoiceContent) {
        this.invoiceContent = invoiceContent;
    }

    @Basic
    @Column(name = "invoice_type")
    public String getInvoiceType() {
        return invoiceType;
    }

    public void setInvoiceType(String invoiceType) {
        this.invoiceType = invoiceType;
    }

    @Basic
    @Column(name = "invoice_money")
    public BigDecimal getInvoiceMoney() {
        return invoiceMoney;
    }

    public void setInvoiceMoney(BigDecimal invoiceMoney) {
        this.invoiceMoney = invoiceMoney;
    }

    @Basic
    @Column(name = "invoice_number")
    public String getInvoiceNumber() {
        return invoiceNumber;
    }

    public void setInvoiceNumber(String invoiceNumber) {
        this.invoiceNumber = invoiceNumber;
    }

    @Basic
    @Column(name = "invoice_time")
    public Timestamp getInvoiceTime() {
        return invoiceTime;
    }

    public void setInvoiceTime(Timestamp invoiceTime) {
        this.invoiceTime = invoiceTime;
    }

    @Basic
    @Column(name = "invoice_issue")
    public String getInvoiceIssue() {
        return invoiceIssue;
    }

    public void setInvoiceIssue(String invoiceIssue) {
        this.invoiceIssue = invoiceIssue;
    }

    @Basic
    @Column(name = "invoice_person")
    public String getInvoicePerson() {
        return invoicePerson;
    }

    public void setInvoicePerson(String invoicePerson) {
        this.invoicePerson = invoicePerson;
    }

    @Basic
    @Column(name = "invoice_remark")
    public String getInvoiceRemark() {
        return invoiceRemark;
    }

    public void setInvoiceRemark(String invoiceRemark) {
        this.invoiceRemark = invoiceRemark;
    }

    @Basic
    @Column(name = "invoice_zt")
    public Integer getInvoiceZt() {
        return invoiceZt;
    }

    public void setInvoiceZt(Integer invoiceZt) {
        this.invoiceZt = invoiceZt;
    }

    @Override
    public String toString() {
        return "Zinvoice{" +
                "invoiceId=" + invoiceId +
                ", clientId=" + clientId +
                ", invoiceContent='" + invoiceContent + '\'' +
                ", invoiceType='" + invoiceType + '\'' +
                ", invoiceMoney=" + invoiceMoney +
                ", invoiceNumber='" + invoiceNumber + '\'' +
                ", invoiceTime=" + invoiceTime +
                ", invoiceIssue='" + invoiceIssue + '\'' +
                ", invoicePerson='" + invoicePerson + '\'' +
                ", invoiceRemark='" + invoiceRemark + '\'' +
                ", invoiceZt=" + invoiceZt +
                '}';
    }
}
